﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace AbstractFactory
{
    public class WoodenRoom : IRoom
    {
        public IWall EastWall { get; set; }
        public IWall SouthWall { get; set; }
        public IWall WestWall { get; set; }
        public IWall NorthWall { get; set; }
    }

    public class WoodenWall : IWall
    {
        public IDoor Door { get; set; }
    }

    public class WoodenDoor : IDoor
    {
        public bool IsOpen { get; set; }
    }

    public class WoodenMazeFactory : IMazeFactory
    {
        public IRoom GetRoom()
        {
            return new WoodenRoom();
        }

        public IWall GetWall()
        {
            return new WoodenWall();
        }

        public IDoor GetDoor()
        {
            return new WoodenDoor();
        }
    }
}